/* generated using openapi-typescript-codegen -- do no edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ROpenIdVo } from '../models/ROpenIdVo';
import type { RString } from '../models/RString';
import type { UserDto } from '../models/UserDto';
import type { UserLoginDto } from '../models/UserLoginDto';
import type { WechatDto } from '../models/WechatDto';

import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';

export class LoginService {

    /**
     * @param requestBody 
     * @returns RString OK
     * @throws ApiError
     */
    public static login(
requestBody: UserLoginDto,
): CancelablePromise<RString> {
        return __request(OpenAPI, {
            method: 'POST',
            url: '/login',
            body: requestBody,
            mediaType: 'application/json',
        });
    }

    /**
     * 微信注册
     * @param requestBody 
     * @returns ROpenIdVo OK
     * @throws ApiError
     */
    public static register(
requestBody: WechatDto,
): CancelablePromise<ROpenIdVo> {
        return __request(OpenAPI, {
            method: 'POST',
            url: '/login/wechat',
            body: requestBody,
            mediaType: 'application/json',
        });
    }

    /**
     * 注册用户信息
     * @param requestBody 
     * @returns RString OK
     * @throws ApiError
     */
    public static register1(
requestBody: UserDto,
): CancelablePromise<RString> {
        return __request(OpenAPI, {
            method: 'POST',
            url: '/login/register',
            body: requestBody,
            mediaType: 'application/json',
        });
    }

}
